package xusage.cumulus.tiles.context;

import javax.servlet.ServletContext;

import org.apache.tiles.TilesApplicationContext;
import org.apache.tiles.servlet.context.wildcard.WildcardServletTilesApplicationContextFactory;

public class CumulusApplicationContextFactory extends WildcardServletTilesApplicationContextFactory {

	public TilesApplicationContext createApplicationContext(Object context) {
		if (context instanceof ServletContext) {
			ServletContext servletContext = (ServletContext) context;
			return new CumulusApplicationContext(servletContext);
		}
		return null;
	}
}
